// src/navigation/ProfileNavigator.tsx
import React from 'react';
import { createStackNavigator, TransitionPresets } from '@react-navigation/stack';
import { TouchableOpacity } from 'react-native';
import Icon from 'react-native-vector-icons/MaterialIcons';

// Profile Screens
import ProfileScreen from '../screens/profile/ProfileScreen';
import SubscriptionScreen from '../screens/profile/SubscriptionScreen';
// import EditProfileScreen from '../screens/profile/EditProfileScreen';
// import ChangePasswordScreen from '../screens/profile/ChangePasswordScreen';
// import NotificationSettingsScreen from '../screens/profile/NotificationSettingsScreen';
// import PrivacyScreen from '../screens/profile/PrivacyScreen';
// import HelpScreen from '../screens/profile/HelpScreen';
// import AboutScreen from '../screens/profile/AboutScreen';
// import FeedbackScreen from '../screens/profile/FeedbackScreen';

export type ProfileStackParamList = {
  ProfileMain: undefined;
  Subscription: undefined;
  EditProfile: undefined;
  ChangePassword: undefined;
  NotificationSettings: undefined;
  Privacy: undefined;
  Help: undefined;
  About: undefined;
  Feedback: undefined;
};

const Stack = createStackNavigator<ProfileStackParamList>();

const ProfileNavigator: React.FC = () => {
  return (
    <Stack.Navigator
      screenOptions={{
        headerStyle: {
          backgroundColor: '#667eea',
          elevation: 0,
          shadowOpacity: 0,
        },
        headerTintColor: '#fff',
        headerTitleStyle: {
          fontWeight: 'bold',
          fontSize: 18,
        },
        headerLeftContainerStyle: {
          paddingLeft: 10,
        },
        ...TransitionPresets.SlideFromRightIOS,
      }}
    >
      <Stack.Screen
        name="ProfileMain"
        component={ProfileScreen}
        options={{
          headerTitle: '个人中心',
          headerShown: false,
        }}
      />
      <Stack.Screen
        name="Subscription"
        component={SubscriptionScreen}
        options={{
          headerTitle: '订阅管理',
          headerLeft: ({ onPress }) => (
            <TouchableOpacity onPress={onPress} style={{ padding: 10 }}>
              <Icon name="arrow-back" size={24} color="#fff" />
            </TouchableOpacity>
          ),
        }}
      />
      {/*<Stack.Screen*/}
      {/*  name="EditProfile"*/}
      {/*  component={EditProfileScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '编辑资料',*/}
      {/*    ...TransitionPresets.ModalSlideFromBottomIOS,*/}
      {/*  }}*/}
      {/*/>*/}
      {/*<Stack.Screen*/}
      {/*  name="ChangePassword"*/}
      {/*  component={ChangePasswordScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '修改密码',*/}
      {/*  }}*/}
      {/*/>*/}
      {/*<Stack.Screen*/}
      {/*  name="NotificationSettings"*/}
      {/*  component={NotificationSettingsScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '通知设置',*/}
      {/*  }}*/}
      {/*/>*/}
      {/*<Stack.Screen*/}
      {/*  name="Privacy"*/}
      {/*  component={PrivacyScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '隐私设置',*/}
      {/*  }}*/}
      {/*/>*/}
      {/*<Stack.Screen*/}
      {/*  name="Help"*/}
      {/*  component={HelpScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '帮助中心',*/}
      {/*  }}*/}
      {/*/>*/}
      {/*<Stack.Screen*/}
      {/*  name="About"*/}
      {/*  component={AboutScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '关于我们',*/}
      {/*  }}*/}
      {/*/>*/}
      {/*<Stack.Screen*/}
      {/*  name="Feedback"*/}
      {/*  component={FeedbackScreen}*/}
      {/*  options={{*/}
      {/*    headerTitle: '意见反馈',*/}
      {/*  }}*/}
      {/*/>*/}
    </Stack.Navigator>
  );
};

export default ProfileNavigator;